<template>
    <div class="apppadding bgfff">
        <bDetail :instance="pForm" class="form" title="预约人信息" cover="80%"></bDetail>
    </div>
    <div class="apppadding bgfff">
        <bDetail :instance="pForm" label_prop="labels_info" class="form" title="订单信息" cover="80%"></bDetail>
    </div>
</template>

<script lang="ts" setup>
import bDetail from "@m/components/public/b_detail.vue";
import { IForm } from "@b/index/nursing_appointment";
import { useRoute, useRouter } from "vue-router";

const pForm = new IForm();
const router = useRouter();
const { id, type } = useRoute().query;
if (type === 'nurse') {
    pForm.url.info = '/nursing_appointment/info/nurse';
} else if (type === 'lender') {
    pForm.url.info = '/nursing_appointment/info/lender';
} else {
    router.back();
}
pForm.id = Number(id);
pForm.setData();
pForm.init();
</script>
